home *** CD-ROM | disk | FTP | other *** search
Text File | 1998-01-19 | 1.6 KB | 34 lines | [TEXT/ToyS] |
- property iconList : [200, 201, 202, 203, 204, 205, 206, 207, 208, 209, 210, 211, 212, 213, 214, 215, 216, 217, 218, 219, 220, 221, 222]
- set textList to []
- set fold to (path to control panels folder) as text
- set fs to list folder fold
- if fs's length > iconList's length then set fs to fs's items 1 thru (iconList's length)
- repeat with f in fs
- set i to info for (fold & f)
- tell i to set textList to textList & [name & tab & (modification date's time string) & tab & size]
- end repeat
-
- set iconListDlog to {size:[500, 306], contents:[¬
- {class:push button, name:"OK", bounds:[418, 276, 490, 296]}, ¬
- {class:push button, name:"Cancel", bounds:[336, 276, 408, 296]}, ¬
- {class:icon list box, contents:iconList, flags:1, bounds:[10, 24, 162, 250], font:5}, ¬
- {class:list box, contents:textList, flags:1, bounds:[180, 24, 490, 250], value:[1, 3, 5], column widths:[150, 80], font:6}, ¬
- {class:group box, bounds:[2, 264, 497, 264]}, ¬
- {class:static text, contents:"Select some here", justification:left, bounds:[10, 4, 180, 20], font:1}, ¬
- {class:static text, contents:"Then select some here", justification:right, bounds:[180, 4, 490, 20], font:1} ¬
- ], name:"Icon List Demo", style:standard window}
-
- dd install with fonts [null, null, null, null, {name:"Geneva", size:9}, {name:"Helvetica", size:12, style:condensed, color:[22222, 0, 0]}] with grayscale
- --dd auto dialog iconListDlog
- set d to dd make dialog iconListDlog
- repeat
- set i to dd interact with user
- if i = 3 then
- dd set value of item 4 of d to (dd get value of item 3 of d)
- else if i = 4 then
- dd set value of item 3 of d to (dd get value of item 4 of d)
- else if i ≤ 2 then
- exit repeat
- end if
- end repeat
- dd uninstall